package com.lace.ctrl.admin.web.company.provider;

import com.lace.common.entity.TbCompanyInfo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

/**
 * Created by Administrator on 2018/7/15.
 */
@FeignClient("service")
public interface TbCompanyProvider {
    @GetMapping("/v1/tbCompanyInfos/")
    Object selectAll();

    @GetMapping("/v1/tbCompanyInfos/bysql")
    Object selectBySql();

    @GetMapping("/v1/tbCompanyInfos/pagebysql")
    Object selectPageBySql(@RequestParam("current") Integer current,@RequestParam("size") Integer size);

    @GetMapping("/v1/tbCompanyInfos/{id}")
    Object findOne(@PathVariable("id") Long id);

    @PostMapping
    Object insert(@RequestBody TbCompanyInfo tbCompanyInfo);

    @DeleteMapping("/v1/tbCompanyInfos/{id}")
    String deleteOne(@PathVariable("id") Long id);

}
